package com.yc.jpyy.mobile.service;


import java.text.ParseException;
import java.util.List;
import java.util.Map;

import org.springframework.dao.DataAccessException;

import com.yc.jpyy.base.bean.RestResponse;

public interface BizService {

	// 获取学员基本信息
	Map<String, Object> getStudentInfo(String userId)
			throws DataAccessException;

	// 获取指定县区编号内的驾校
	List<Map<String, Object>> SelectDriverSchools(String RegionNo)
			throws DataAccessException;

	// 修改学员图片
	int updateUserImage(String userImage, String userId)
			throws DataAccessException;
	
	// 查询提醒时间
	List<Map<String, Object>> checkRemind(int minute)
			throws DataAccessException;

	// 查询公告
	List<Map<String, Object>> checkSysAnn(int minute)
			throws DataAccessException;

	// 获取修改课程信息
	List<Map<String, Object>> getUpdateCourseNo(int minute)
			throws DataAccessException;

	// 获取收藏试题
	RestResponse getCollectionQuestions(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 获取错题试题
	RestResponse getWrongQuestions(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 删除错题试题
	RestResponse deleteWrongQuestions(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 获取模拟试题
	RestResponse getSimulateQuestions(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 获取难题试题
	RestResponse getDifficultQuestions(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 获取模考信息
	RestResponse getSimulateInfo(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 获取专项练习题
	RestResponse getSpecialTypeQuestion(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 添加答题记录
	RestResponse addQuestionInfo(Map<String, Object> paramsMap,RestResponse response)throws DataAccessException;

	// 添加收藏问题
	RestResponse addQuestionCollect(Map<String, Object> paramsMap,RestResponse response)throws DataAccessException;

	// 添加模考记录
	RestResponse addExamRecord(Map<String, Object> paramsMap,RestResponse response)throws DataAccessException;

	// 驾校信息查询---参数机构ID
	RestResponse getDriveSchoolInfo(Map<String, Object> paramMap,
			RestResponse response) throws DataAccessException;

	// 根据驾校ID获取班型--参数驾校id
	RestResponse getClassInfoByDriverId(Map<String, Object> hashMap,RestResponse response)
			throws DataAccessException;

	// 驾校信息查询--参数驾校名称
	List<Map<String, Object>> getDrivesInfo(Map<String, Object> paramsMap)
			throws DataAccessException;


	// 根据题目ID获取选项
	List<Map<String, Object>> getQuestionItemInfo(String questionid)
			throws DataAccessException;

	// 根据驾校ID获取教练下拉
	List<Map<String, Object>> getTeacherListBySchoolID(
			Map<String, Object> paramsMap) throws DataAccessException;

	// 根据区县编号教练列表
	RestResponse getTeacherListByRegion(Map<String, Object> paramsMap,
			RestResponse response) throws DataAccessException;

	// 根据教练ID获取教练详情
	Map<String, Object> getTeacherDetailById(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 根据学员ID获取意见反馈下拉
	List<Map<String, Object>> getFeedbackListInfo(int stuId)
			throws DataAccessException;

	// 登录
	RestResponse LoginSystemInfo(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 获取章节分类
	RestResponse getSecondConfigInfo(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 获取专项分类
	RestResponse getSpecialSecondConfig(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 获取系统公告
	RestResponse getNews(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 获取报名意向信息
	List<Map<String, Object>> getPreRegistrationByTel(String studentTel)
			throws DataAccessException;

	// 添加意见反馈信息
	int addFeedBack(Map<String, Object> paramsMap) throws DataAccessException;

	// 获取学时
	Map<String, Object> getLearnTimeByStuId(String studentId, String imgUrl)
			throws DataAccessException;

	// 获取预约学时信息
	Map<String, Object> getAppointmentLearnTimeByStuId(String studentId)
			throws DataAccessException;

	// 获取班型名称
	List<Map<String, Object>> getClassTypeById(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 获取购物车数量
	String getShopCount(String studentId) throws DataAccessException;

	// 获取学习明细信息
	List<Map<String, Object>> getStudyRecordDetailByStuIdAndSubjectID(
			String studentId) throws DataAccessException;

	// 获取个人信息
	Map<String, Object> getPersonalInformationByTel(
			Map<String, Object> paramsMap) throws DataAccessException;

	// 获取我的信息（根据ID）
	Map<String, Object> getMyInformationById(Map<String, Object> parm)
			throws DataAccessException;

	// 根据电话号码修改学员账号表
	RestResponse updateInfo(RestResponse response,Map<String, Object> paramsMap)
			throws DataAccessException;

	// 累加驾校咨询数量
	int updateDriveSchoolConsultNum(Map<String, Object> paramsMap)
			throws DataAccessException;


	// 课程评价接口
	RestResponse CurriculumEvaluation(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 获取课程评价接口
	RestResponse getCourseEvaluate(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 取消预约页面---查询详细课程信息 根据课程编号查询
	List<Map<String, Object>> CancelAppointInfo(Map<String, Object> paramsMap)
			throws DataAccessException;


	// 查询未开课程
	List<Map<String, Object>> NoCourseHistory(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 待评价课程
	List<Map<String, Object>> waitCourseHistory(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 完成课程
	List<Map<String, Object>> finishCourseHistory(String stuid)
			throws DataAccessException;

	// 更具课程编号查预约记录编号
	Integer queryCourseNo(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 条件查询预约记录编号
	Integer finishQueryCourseNo(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 查询详细课程信息
	List<Map<String, Object>> detailsClass(int Id, String imgUrl)
			throws DataAccessException;

	// 获取课程列表
	List<Map<String, Object>> GetTecReleaseCourse(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 查询详细课程信息
	List<Map<String, Object>> GetTecRAppointmentInfo(int courseid, String imgUrl)
			throws DataAccessException;

	// 获取课程列表
	RestResponse getReleaseCourse(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;

	// 照片上传
	int Insertcheckpic(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 更新 StudyStat_Query
	int updateStudyStat_Query(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 更新 StudyStat_Student
	int updateStudyStat_Student(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 更新 StudyStatByDay
	int updateStudyStatByDay(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 获取照片
	List<Map<String, Object>> getphotobystuid(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 获取参数
	Map<String, Object> getSubjectParambysubjectid(int subjectid)
			throws DataAccessException;

	// 根据学员id获取query数据
	Map<String, Object> getStudyStat_Querybystuid(int userid)
			throws DataAccessException;

	// 根据科目id、学驾类型获取大纲数据
	Map<String, Object> getSchoolSubjectsbysubid(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 学习结果表
	int InsertStuExamResult(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 获取学员已学、未学视频课程
	RestResponse  getStudentLearnVideo(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 获取用户已学、未学视频课程
	RestResponse  getUserLearnVideo(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	
	// 获取视频所属课程列表
	List<Map<String, Object>> getCurVideo(Map<String, Object> paramsMap)
			throws DataAccessException;

	// 获取前三张驾校照片
	List<Map<String, Object>> getDriverSchoolPhotos(String imgUrl)
			throws DataAccessException;

	// 修改学员基础信息表的gid
	int updateStuGid(Map<String, Object> paramsMap) throws DataAccessException;

	// 学习照片上传
	int addStudyPhoto(Map<String, Object> paramsMap) throws DataAccessException;

	// 视频学习照片上传
	int addVideoPhoto(Map<String, Object> paramsMap) throws DataAccessException;

	
	//获取视频信息
    RestResponse getVideoInfo(Map<String, Object> paramsMap, RestResponse response)
    		throws DataAccessException;
    
	//添加视频学习记录
    RestResponse addStudyResult(Map<String, Object> paramsMap, RestResponse response)
    		throws DataAccessException;
    
	//添加视频学习记录
    RestResponse addVideoRecord(Map<String, Object> paramsMap, RestResponse response)
    		throws DataAccessException;

	// 2.1 学员基本信息获取-终端
	List<Map<String, Object>> getStudentInfoForTerminater(
			Map<String, Object> paramsMap) throws DataAccessException;

	// 2.4 学员学时信息-终端
	List<Map<String, Object>> getStudyTimeQueryForTerminater(String Stunum,
			String Subject) throws DataAccessException;

	// 2.6 电子教学日志-终端
	List<Map<String, Object>> getStudyRecordResultForTerminater(String Stunum)
			throws DataAccessException;

	// 2.7 添加操作日志-终端
	int addOperateLog(Map<String, Object> paramsMap) throws DataAccessException;

	// 根据设备编号查VehicleId-人脸识别
	Integer getVehicleIdForFaceCheck(String Devnum) throws DataAccessException;

	// 根据设备编号查GpsId-人脸识别
	Integer getGpsIdForFaceCheck(Integer VehicleId) throws DataAccessException;

	// 根据学员全国编号查UID-人脸识别
	String getUIDForFaceCheck(String Stunum) throws DataAccessException;

	// 根据学员身份证UID查重-人脸识别
	int isExistUIDForFaceCheck(String UID) throws DataAccessException;

	// 根据学员全国编号修改身份证UID-人脸识别
	int updateUIDForFaceCheck(String UID, String Stunum)
			throws DataAccessException;

	// 根据状态拿到课程所有信息
	List<Map<String, Object>> getCourseDetailByStatus(
			Map<String, Object> paramsMap) throws DataAccessException;


	//用户注册
	RestResponse userRegister(Map<String, Object> paramsMap,RestResponse response)
			throws DataAccessException;
	//修改密码
	RestResponse updatePassword(String mobilePhone,String oldPwd,String newPwd,RestResponse response)
			throws Exception;
	//修改用户头像
	RestResponse updateUserPhoto(String userId,String image64Base,RestResponse response)
			throws Exception;
	// 修改学员登录密码
	int updateStuPwd(String pwd, String mobilePhone)
			throws DataAccessException;
	
	RestResponse BIndOrNot(Map<String, Object> paramsMap,RestResponse response)
			throws Exception;

	RestResponse activeStudent(Map<String, Object> paramsMap,RestResponse response)
				throws Exception;
	//获取驾校详情
	RestResponse getDriverSchoolDtail(String driverId,String driveType,String imgUrl,RestResponse response)
				throws DataAccessException;
	//获取教练所在的驾校
	Map<String, Object> getDriverByTeacher(String teacherId)
					throws DataAccessException;
	//预约课程
	RestResponse courseAppoint(Map<String,Object> paramsMap,RestResponse response)
			        throws DataAccessException,ParseException;
	//取消预约课程
	RestResponse deleteAppoint(Map<String,Object> paramsMap,RestResponse response)
				    throws DataAccessException;
	//获取首页数据
	RestResponse selectPageDatas(Map<String,Object> valMap,String studentId,String subjectId,RestResponse response)
				    throws DataAccessException;	
	//查询试题
	RestResponse selectQuestion(Map<String,Object> valMap,RestResponse response)
					throws DataAccessException;	
	//添加报名意向
	RestResponse addPreRegister(Map<String,Object> valMap,RestResponse response)
					throws DataAccessException;	
	//测试事务
	int updateUserInfo(int userId)throws DataAccessException;
	//测试多参数
	int InsertInfo(Map<String,Object> map)throws DataAccessException;
	
	//添加图片
	RestResponse addStudyPhoto(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	
	//添加教练或驾校评价
	RestResponse addStudentEvaluate(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	//添加视频评价
	RestResponse addVideoEvaluate(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	
	//获取教练或驾校的评价
	RestResponse getStudentEvaluate(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	//获取视频的评价
	RestResponse getVideoEvaluate(String videoId,String imgUrl,RestResponse response)
			throws Exception;
	
	//校验教练或驾校只能评价一次
	RestResponse checkStudentEvaluateOne(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	
	//校验视频只能评价一次
	RestResponse checkVideoEvaluateOne(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	
	//校验课程只能评价一次且是上过的课程
	RestResponse checkCourseEvaluateOne(Map<String,Object> valMap,RestResponse response)
			throws Exception;
	
	//获取视频学习记录
	RestResponse getVideoRecordList(String userId,RestResponse response)
			throws Exception;
	
	//获取模拟考试记录
	RestResponse getExamRecordList(String userId,RestResponse response)
			throws Exception;
	// 插入异常日志
	RestResponse writeAbnormalLog(List<Map<String,Object>> listMap,RestResponse response) throws DataAccessException;	
	
	// 根据通讯号查设备号
	Map<String, Object> getDevnumByPhone(String factoryNo) throws DataAccessException;
}
